<?php
namespace app\admin\model;

use think\Model;
use think\Db;

class AuthGroupModel extends Model
{
    // 指定表名,不含前缀
    protected $name = 'auth_group';
    //主键名
    protected $pk = 'id';

    public function getRuleInfo($group_id)
    {
        return $this->where('id', $group_id)->find();
    }

    public function getRuleById($group_id)
    {
        return $this->where('id', $group_id)->find();
    }

    /**
     * 获取所有的角色信息
     */
    public function getRuleList()
    {
        return $this->select();
    }

}